using System;
using System.Collections.Generic;
using System.Text;
using NUnit.Framework;
using OpenTK.Math;
using Dogfight2008.Common;

namespace Dogfight2008.Tests
{
  [TestFixture]
  public class RotatedBody2dFixture
  {
    [Test]
    public void Constr()
    {
      RotatedBody2d b = new RotatedBody2d();
    }

    [Test]
    public void InitialValues()
    {
      RotatedBody2d b = new RotatedBody2d();
      Assert.IsTrue(T.VecEq(Q.v(0, 0), b.Position));
      Assert.IsTrue(T.VecEq(Q.v(0, 0), b.Velocity));
      Assert.AreEqual(0, b.Angle);
    }

    [Test]
    public void MoveRight()
    {
      RotatedBody2d b = new RotatedBody2d();
      b.Velocity = Q.v(1, 0);
      b.Tick(1.0);
      Assert.IsTrue(T.VecEq(Q.v(1, 0), b.Position));
    }
  }
}
